package com.yixia.pea.domain.credit;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.math.BigDecimal;

import lombok.Data;

/**
 * 
 * @TableName pea_cre_score
 */
@TableName(value ="pea_cre_score")
@Data
public class PeaCreScore implements Serializable {
    /**
     * 信用评分主键
     */
    @TableId(value = "sc_id", type = IdType.AUTO)
    private Long scId;

    /**
     * 户主ID
     */
    @TableField(value = "hz_id")
    private Long hzId;

    /**
     * 劳动力评分
     */
    @TableField(value = "lader_score")
    private BigDecimal laderScore;

    /**
     * 家庭产业评分
     */
    @TableField(value = "fam_cy_score")
    private BigDecimal famCyScore;

    /**
     * 家庭人均纯收入评分
     */
    @TableField(value = "fam_num_score")
    private BigDecimal famNumScore;

    /**
     * 定性评分
     */
    @TableField(value = "ding_xin_score")
    private BigDecimal dingXinScore;

    /**
     * 信用评分
     */
    @TableField(value = "credit_score")
    private String creditScore;

    /**
     * 信用等级
     */
    @TableField(value = "credit_darge")
    private String creditDarge;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        PeaCreScore other = (PeaCreScore) that;
        return (this.getScId() == null ? other.getScId() == null : this.getScId().equals(other.getScId()))
            && (this.getHzId() == null ? other.getHzId() == null : this.getHzId().equals(other.getHzId()))
            && (this.getLaderScore() == null ? other.getLaderScore() == null : this.getLaderScore().equals(other.getLaderScore()))
            && (this.getFamCyScore() == null ? other.getFamCyScore() == null : this.getFamCyScore().equals(other.getFamCyScore()))
            && (this.getFamNumScore() == null ? other.getFamNumScore() == null : this.getFamNumScore().equals(other.getFamNumScore()))
            && (this.getDingXinScore() == null ? other.getDingXinScore() == null : this.getDingXinScore().equals(other.getDingXinScore()))
            && (this.getCreditScore() == null ? other.getCreditScore() == null : this.getCreditScore().equals(other.getCreditScore()))
            && (this.getCreditDarge() == null ? other.getCreditDarge() == null : this.getCreditDarge().equals(other.getCreditDarge()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getScId() == null) ? 0 : getScId().hashCode());
        result = prime * result + ((getHzId() == null) ? 0 : getHzId().hashCode());
        result = prime * result + ((getLaderScore() == null) ? 0 : getLaderScore().hashCode());
        result = prime * result + ((getFamCyScore() == null) ? 0 : getFamCyScore().hashCode());
        result = prime * result + ((getFamNumScore() == null) ? 0 : getFamNumScore().hashCode());
        result = prime * result + ((getDingXinScore() == null) ? 0 : getDingXinScore().hashCode());
        result = prime * result + ((getCreditScore() == null) ? 0 : getCreditScore().hashCode());
        result = prime * result + ((getCreditDarge() == null) ? 0 : getCreditDarge().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", scId=").append(scId);
        sb.append(", hzId=").append(hzId);
        sb.append(", laderScore=").append(laderScore);
        sb.append(", famCyScore=").append(famCyScore);
        sb.append(", famNumScore=").append(famNumScore);
        sb.append(", dingXinScore=").append(dingXinScore);
        sb.append(", creditScore=").append(creditScore);
        sb.append(", creditDarge=").append(creditDarge);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}